package com.example.water.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.example.water.pojo.StSitinfoB;
import com.example.water.pojo.StSoilR;
import com.example.water.service.StSoilRService;
import com.example.water.mapper.StSoilRMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
* @author Lin
* @description 针对表【st_soil_r(雨量信息表)】的数据库操作Service实现
* @createDate 2023-11-09 22:05:54
*/
@Service
public class StSoilRServiceImpl extends ServiceImpl<StSoilRMapper, StSoilR>
    implements StSoilRService{
    @Autowired
    private StSoilRMapper stSoilRMapper;
    @Override
    public List<StSitinfoB> getStSoilRPage(Integer pageSize, Integer currentPage) {
        currentPage=(currentPage-1)*pageSize;


        return stSoilRMapper.getPage(pageSize,currentPage);
    }

    @Override
    public Integer getAllCount() {
        return stSoilRMapper.getCount();
    }

    @Override
    public List<StSitinfoB> getMaxSoil(Integer pageSize, Integer currentPage) {
        currentPage=(currentPage-1)*pageSize;
        return stSoilRMapper.getMaxSoil(pageSize,currentPage);
    }

    @Override
    public Integer getMaxAllCount() {
        return stSoilRMapper.getMaxAllCount();
    }
}




